package tichu_project252.View.Player;

import javax.swing.JButton;
import tichu_project252.Controller.playHandler;
import tichu_project252.Model.Model;

/**
 * This class implements the event handler of playing cards.
 *
 * This action listener is implemented to define what should be done when an
 * user puss the Button play Cards..
 *
 * @see <a
 * href="http://docs.oracle.com/javase/tutorial/uiswing/events/actionlistener.html">actionListener</a>
 *
 * @author Alexandra Barka, ΑΜ: 2867, login : barka.
 * @version %I%, %G%
 *
 */
public class playCardsButton extends JButton {

    /**
     * Constructs a new Play Cards Button.
     *
     * <p><b>Constructor: </b> playCardsButton(Model m) </p>
     *
     * <p><b>Precondition: </b> </p> <p><b>Postcondition: </b> Constructs a new
     * JButton </p>
     *
     * @param m The model
     */
    public playCardsButton(Model m) {
        super("Play Cards");            //Constructs a JButton with "Play Cards" label.
        this.addActionListener(new playHandler(m));
    }
}
